<?php

namespace App\Library\Requests\Feedback;

use App\Library\Requests\Base\BaseDTORequest;
use App\Library\Rules\MediasImgRule;

class FeedbackAddRequest extends BaseDTORequest
{
    public function rules(): array
    {
        return [
            'type' => 'required|integer|between:1,7',
            'sourceId' => 'required|integer|min:0',
            'content' => 'required|string|max:5000',
            'mobile' => 'required|string|size:11|regex:' . __('com.mobileReg'),
            'fileIds' => ['nullable', 'array', new MediasImgRule],
        ];
    }
}
